serviceworker
Limited availability
This feature is not Baseline because it does not work in some of the most widely-used browsers.
Experimental: This is an experimental technology
Check the Browser compatibility table carefully before using this in production.
Non-standard: This feature is not standardized. We do not recommend using non-standard features in production, as they have limited browser support, and may change or be removed. However, they can be a suitable alternative in specific cases where no standard option exists.
The serviceworker
member specifies a serviceworker that is Just-In-Time (JIT)-installed and registered to run a web-based payment app providing a payment mechanism for a specified payment method in a merchant website. See Payment Handler API for more details.
Values
serviceworker
objects may contain the following values:
scope
Experimental Non-standard-
A string representing the service worker's registration scope.
src
Experimental Non-standard-
A string representing the URL to download the service worker script from.
use_cache
Experimental Non-standard-
A boolean that sets how the HTTP cache is used for service worker script resources during updates. It provides equivalent functionality to certain values of the
updateViaCache
option provided when a service worker is registered via JavaScript usingServiceWorkerContainer.register()
.true
: The HTTP cache will be queried for imports, but the main script will always be updated from the network. If no fresh entry is found in the HTTP cache for the imports, they're fetched from the network. Equivalent toupdateViaCache: "imports"
.false
: The HTTP cache will not be used for the main script or its imports. All service worker script resources will be updated from the network. Equivalent toupdateViaCache: "none"
.
Examples
Specifications
No specification found
No specification data found for manifests.webapp.serviceworker
.
Check for problems with this page or contribute a missing spec_url
to mdn/browser-compat-data. Also make sure the specification is included in w3c/browser-specs.